%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% THE AMPLIFICATION OF RISK IN EXPERIMENTAL DIFFUSION CHAINS %%
%% Mehdi Moussaid, Henry Brighton, & Wolfgang Gaissmaier      %%
%%              SIMULATION PROGRAM                            %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


%% Initialisation of simulation parameters %%

% The average risk perception of the agents before the social transmission starts. 
%Risk perception ranges from 0 (relaxed agents) to 1 (worried agents)
avgInitialRP = 0.75 ;
% The standard deviation of the above average risk perception
stdInitialRP = 0 ;

% Total number of positive or negative statements in the incoming message
totalS = 20;
% The number of positve statements in the message (safe)
ns = 10;
% The number of negative statements in the message (dangerous)
nd = totalS - ns;

% The social influence factor, ranging from 0 (agents are not influenced by
% others) to 1 (agents completely adhere to other people's judgment)
si = 0.5 ;

% The length of the diffusion chain
Ni = 50;

%Display parameter: change to 0 to disable the display of the results
DISPLAY = 1 ;

%% Execution of the simulation program with the above parameters
[ RP MD RPo] = simulation(avgInitialRP , stdInitialRP , ns  , nd , si , Ni, DISPLAY);






